/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package sharepoint3;

import com.microsoft.schemas.sharepoint.soap.Lists;
import java.net.Authenticator;
import java.net.PasswordAuthentication;

/**
 *
 * @author Thyago
 */
public class NtlmAuthenticator extends Authenticator{
    private final String username;
    private final char[] password;
    com.microsoft.schemas.sharepoint.soap.ListsSoap port = null;
    com.microsoft.schemas.sharepoint.soap.Lists service = new Lists();

    public NtlmAuthenticator(final String username, final String password) {
        super();
        this.username = new String(username);
        this.password = password.toCharArray();
    }
    @Override
    public PasswordAuthentication getPasswordAuthentication() {
        return (new PasswordAuthentication(username, password));
    }
}
